96c71cf059bea96da948a22050c09bf83bdc972c,camel-core/src/main/java/org/apache/camel/util/ExchangeHelper.java,ExchangeHelper,populateVariableMap,#Exchange#Map#,313
Before Change
map.put("headers", in.getHeaders());
map.put("body", in.getBody());
if (isOutCapable(exchange)) {
Message out = exchange.getOut();
map.put("out", out);
map.put("response", out);
}
After Change
// if we are out capable then set out and response as well
// however only grab OUT if it exists, otherwise reuse IN
// this prevents side effects to alter the Exchange if we force creating an OUT message
Message msg = exchange.hasOut() ? exchange.getOut() : exchange.getIn();
map.put("out", msg);
map.put("response", msg);
}